﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace X13.Player
{
    [Serializable]
    public sealed class PlayerProfile
    {
        //Fields / Props
        public string Name { get; private set; }

        public int Balance
        { 
            get;
            private set;
        }
        
        public PlayerProfile(string name)
        {
            this.Name = name;
        }

        public void AddCurrency(int amount)
        {
            Balance += amount;
        }
        public bool AddCharge(int amount)
        {
            if (Balance < amount)
                return false;

            Balance -= amount;
            return true;
        }
    }
}
